package com.alibaba.citrus.ots.common.model;


import lombok.Getter;
import lombok.Setter;

import java.io.Serializable;
import java.util.List;

/**
 * @author luyi
 * @date 2021/11/6 5:11 下午
 */
@Getter
@Setter
public abstract class ImportRequest implements Serializable {
    private static final long serialVersionUID = -6279092521661661620L;
    /**
     * 错误描述
     */
    private String errorMessage;


    public static <T extends ImportRequest> List<T> setRequestErrorMessage(List<T> requestList, String errorMessage){
        requestList.forEach(importRequest -> importRequest.setErrorMessage(errorMessage));
        return requestList;
    }

}
